/* Copyright (c) Soon.Liao 2024. All rights reserved.
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 * Create Date : 2024
 * @Date: 2024-10-14 07:57:06
 * @LastEditors: soon.liao
 * @LastEditTime: 2024-10-26 14:09:45
 * @FilePath: /src/application/ws63/rgb_master/rgbled/sence.h
 * @Description: NA
 * NA
 */
#pragma once
#include <stdint.h>

#define MAX_PRESET_DATA_LEN 100
#define PRESET_LEDS_DATA_NUMBERS 30

typedef enum {
    LED_OFF = 0,
    LED_ON = 1,
} status_t;

typedef enum {
    MODE_INDEX_0 = 0,
    MODE_INDEX_1 = 1,
    MODE_INDEX_MAX = 2,
} mode_index_t;

typedef enum {
    SENCE_INDEX_0 = 0,
    SENCE_INDEX_1 = 1,
    SENCE_INDEX_2 = 2,
    SENCE_INDEX_3 = 3,
    SENCE_INDEX_4 = 4,
    SENCE_INDEX_5 = 5,
    SENCE_INDEX_6 = 6,
    SENCE_INDEX_7 = 7,
    SENCE_INDEX_8 = 8,
    SENCE_INDEX_9 = 9,
    SENCE_INDEX_10 = 10,
    SENCE_INDEX_MAX = 11
} sence_index_t;

#ifdef __cplusplus
extern "C" {
#endif

void rgb_led_strip_next_mode(void);
void rgb_led_strip_perv_mode(void);

void rgb_led_strip_next_sence(void);
void rgb_led_strip_perv_sence(void);

void rgb_led_strip_sence_task(void);

// 设置LED条的亮度增加
void rgb_led_strip_add_brightness(void);
// 设置LED条的亮度减少
void rgb_led_strip_min_brightness(void);
// 设置LED条的亮度
void rgb_led_strip_set_brightness(uint8_t value);

void rgb_led_strip_set_on(void);
void rgb_led_strip_set_off(void);

void rgb_led_strip_toggle(void);

void rgb_led_strip_set_by_rgb(uint8_t r, uint8_t g, uint8_t b);

#ifdef __cplusplus
}
#endif